# Contributor: Saijin-Naib <Saijin-Naib_package-maintenance@outlook.com>
# Maintainer: Saijin-Naib <Saijin-Naib_package-maintenance@outlook.com>
pkgname=libopenraw
pkgver=0.3.1
pkgrel=0
pkgdesc="Desktop agnostic effort to support digital camera RAW files"
url="https://libopenraw.freedesktop.org/"
arch="all !s390x !riscv64"
license="LGPL-3.0-or-later"
makedepends="
	autoconf
	autoconf-archive
	automake
	boost-dev
	cargo
	curl-dev
	gdk-pixbuf-dev
	libjpeg-turbo-dev
	libxml2-dev
	m4
	rust
	"
subpackages="$pkgname-dev"
source="https://libopenraw.freedesktop.org/download/libopenraw-$pkgver.tar.bz2"

prepare() {
	default_prepare
	update_config_sub
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr
	make
}

check() {
	make check
}

package() {
	make install DESTDIR="$pkgdir"
}

sha512sums="
57fb4cadd439a828f223d86f0f1604ac7e6bb443cb0ee8f725b18fc90da2d5b0fbb682d4be0568eb021dea42bb13ba70f5b025d332c5d5db284fcaf985c25e66  libopenraw-0.3.1.tar.bz2
"
